package org.idea.qiyu.framework.jmh.demo;

import java.util.HashMap;

/**
 * @Author linhao
 * @Date created in 11:00 下午 2021/12/16
 */
public class HashMapTestDemo {

    public static void addHashMap(){
        HashMap hashMap = new HashMap();
        long begin = System.currentTimeMillis();
        StringBuffer item = new StringBuffer();
        for (int i = 0; i < 100000; i++) {
            item = item.append("-");
        }
        long end = System.currentTimeMillis();
        System.out.println("StringBuffer 耗时：" + (end - begin) + "ms");
    }
}
